package com.neulogistics.contrib.usercenter.api.application.command;

import com.blackto.lib.mediat.unicast.IRequest;
import com.neulogistics.contrib.usercenter.api.application.viewmodel.LoginUserViewModel;
import com.neulogistics.infrastructure.common.serviceresult.BaseResponse;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;

@Data
public class LoginCommand implements IRequest<BaseResponse<LoginUserViewModel>>, Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * 用户名
     */
    @NotBlank
    @Size(max = 20)
    public String username;

    /**
     * 密码
     */
    @NotBlank
    @Size(max = 100)
    public String password;
}
